﻿using System;

namespace _29_实现多个接口_继承与多态
{
    class Program
    {
        static void Main(string[] args)
        {
            OneWork ow = new OneWork();
            ow.StartWork();
            ow.EndWork();
        }
    }

    interface IRuner1
    {
        void StartWork();
    }

    interface IRuner2
    {
        void EndWork();
    }

    class OneWork:IRuner1, IRuner2
    {
        public void EndWork()
        {
            int i = 0;
            do
            {
                Console.WriteLine(i);
                i++;
            } while (i<5);

            Console.WriteLine("结束操作.");
        }

        public void StartWork()
        {
            Console.WriteLine("这是第一步开始操作-------------------：");
            int i = 0;
            while (i<9)
            {
                Console.WriteLine(i);
                i++;
            }
            Console.WriteLine("开始操作。");
        }


    }

}
